<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@page import="java.util.*"%>
<%@page import="java.lang.String"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>个人信息</title>
<link rel="stylesheet" href="styles/layout.css" type="text/css" />
<!-- -->
<script type="text/javascript" src="scripts/jquery-1.4.1.min.js"></script>
<script type="text/javascript" src="scripts/jquery.slidepanel.setup.js"></script>
<script type="text/javascript" src="scripts/jquery.cycle.all.js"></script>
<script type="text/javascript" src="scripts/jquery.cycle.setup.js"></script>
</head>
<body>
	<%if(session.isNew()||session.getAttribute("username").toString()==""){%>
	<jsp:forward page="IndexAction"></jsp:forward>
	<%}%>
	<div class="wrapper col0">
		<div id="topbar">
			<div id="userinfopanel">
				<ul>
					<li class="left">你好， <%=session.getAttribute("username").toString() %></li>
					<li class="center"><a href="#">我的信息</a></li>
					<li class="right"><a href="/driftbook/IndexAction">注销登录</a></li>
				</ul>
			</div>
		</div>
	</div>
	<!--
########################################################################################## -->
	<div class="wrapper col1">
		<div id="header">
			<div id="logo">
				<a href="#"><img id="logoimg" src="images/logo_slat.jpg" /></a>
				<!--<p>漂书系统</p>-->
			</div>
			<div id="topnav">
				<ul>
					<li><a href="driftAfterLogin.jsp">首页</a></li>
					<li class="active"><a href="BreifAction">漂书</a></li>
					<li><a href="search.jsp">搜索</a></li>
					<li class="last"><a href="donate.jsp">捐书</a></li>
				</ul>
			</div>
			<br class="clear" />
		</div>
	</div>
	<!--
########################################################################################## -->
	<div class="wrapper col2"></div>
	<!--
########################################################################################## -->
	<div class="wrapper col3">
		<div id="homecontent">
			<h1>
				<span> <%=(String)session.getAttribute("username")%></span>的漂书信息
			</h1>
			<h6 id="briefinfo">
				已借阅：<%=session.getAttribute("hasreadcount") %>本，待漂：<%=session.getAttribute("waitdriftcount")%>本，捐赠了：<%=session.getAttribute("bookdonatorcount")%>本
			</h6>
			<div class="detailinfo">
				<div class="leftinfo">
					<img id="defaultbook" src="images/6113596_124247345000_2.jpg">
				</div>
				<div class="rightinfo">
					<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;您目前没有借阅书籍</p>
					<form id="btnpanel" method="post">
						<br /> <input type="hidden" name="username" value="" /> <br />
						<a id="finish" class="btn" href="/driftbook/search.jsp">我要找书</a> <a
							id="delay" class="btn" href="/driftbook/brief.jsp">随便看看</a>
					</form>
				</div>
				<br class="clear" />
			</div>
			<hr />
			<div class="borrowhistory">
				<h6>我的借阅记录</h6>
				<table>
					<thead>
						<tr>
							<th>书名
							</td>
							<th>借阅日期
							</td>
							<th>完成日期
							</td>
						</tr>
					</thead>
					<tbody>
						<% 
        	String i=session.getAttribute("newuser").toString();
       		if(i!="1"){
        	List<String>info1=(List<String>)session.getAttribute("L1") ;
        	List<Date>info2=(List<Date>)session.getAttribute("L2") ;
        	List<Date>info3=(List<Date>)session.getAttribute("L3") ;
        	Iterator<String>itr1= info1.iterator();Iterator<Date>itr2= info2.iterator();Iterator<Date>itr3= info3.iterator();
        	while(itr1.hasNext()&&itr2.hasNext()&&itr3.hasNext()){
        %>
						<tr>
							<td><%=itr1.next()%></td>
							<td><%=itr2.next().toString().substring(0,10)%></td>
							<td><%=itr3.next().toString().substring(0,10)%></td>
						</tr>
						<% }}%>
					</tbody>
				</table>
			</div>
		</div>
	</div>
	<!--
########################################################################################## -->
	<div class="wrapper col5">
		<div id="copyright">
			<p class="fl_left">
				Copyright &copy; 2012 - All Rights Reserved - <a href="#">Shanghai
					University Opensource Community</a>
			</p>
			<br class="clear" />
		</div>
	</div>
</body>
</html>